<template>
	<view class="login_box" >
		<view class="login">
			<view class="logo_box">
				<image :src="clientLogo" mode="aspectFill" class="logo"></image>
			</view>
			<view>
				<Account></Account>
			</view>
			<view v-if="reg_type != 3" class="reg_box" @click="gotoReg">还没有账号，立即注册</view>
			<!-- <view class="reg_box" @click="gotoReg">还没有账号，立即注册</view> -->
		</view>
	</view>
</template>

<script>
	import Account from './account.vue'
	export default {
		components:{Account},
		data() {
			return {
				clientLogo: '',
				account:false,
				reg_type:0,
			}
		},
		onLoad() {
			this.getImgTitle()
		},
		methods: {
			getImgTitle() {
				uni.setStorageSync('SET_CLIENT_NAME', 'demo手机端')
				uni.setStorageSync('SET_CLIENT_LOGO', 'http://127.0.0.1:9300/statics/2024/01/19/2cd53cdbb6fd5266b8587427ed18972bd40736b4_20240119105525A002.jpg')
				this.reg_type = 1
				// this.https('/client/client/conf', {}).then(res => {
				// 	this.clientLogo = res.data.clientLogo
				// 	uni.setStorageSync('SET_CLIENT_NAME', res.data.clientName)
				// 	uni.setStorageSync('SET_CLIENT_LOGO', res.data.clientLogo)
				// })
				// this.https('/client/register/method',{}).then(res=>{
				// 	 this.reg_type = res.data
				// })
			},
			gotoReg(){
				uni.navigateTo({
					url:'/pages/reg/reg'
				})
			},
		}

	}
</script>

<style lang="scss" scoped>
	.login_box {
		width: 100vw;
		height: 100vh;
		background: #000000;
		position: relative;

		.login {
			position: absolute;
			top: 0;
			left: 0;
			z-index: 1;
			width: 100vw;
			height: 100vh;
			background: linear-gradient(to bottom, rgba(66, 83, 216, .8), rgba(213, 51, 186, .5));
			.logo_box{
				width: 200upx;
				height: 200upx;
				margin: 200upx auto 100upx;
				overflow: hidden;
				.logo{
					width: 200upx;
					height: 200upx;
					border-radius: 120upx;
				}
			}
			.reg_box{
				text-align: center;
				position: fixed;
				bottom: 100upx;
				width: 750upx;
				left: 0;
				color: #ffffff;
			}
		}
	}
</style>